package com.ssy.lingxi.member.merchant.entity;

import javax.persistence.*;
import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 会员投诉记录
 * @author 万宁
 * @version 2.0.0
 * @date 2020-07-16
 */
@Entity
@Table(schema = "public", name = "ms_mc_member_complain_history", indexes = {@Index(name="ms_mc_member_complain_history_member_id_idx", columnList = "memberId"), @Index(name="ms_mc_member_complain_history_role_id_idx", columnList = "roleId"),@Index(name="ms_mc_member_complain_history_sub_member_id_idx", columnList = "subMemberId"),@Index(name="ms_mc_member_complain_history_sub_role_id_idx", columnList = "subRoleId"), @Index(name="ms_mc_member_complain_history_rel_type_idx", columnList = "relType"), @Index(name="ms_mc_member_complain_history_create_time_idx", columnList = "createTime")})
public class MemberComplainHistoryDO implements Serializable {
    private static final long serialVersionUID = 3678314512797440934L;

    /**
     * 记录id
     */
    @Id
    @GeneratedValue(strategy= GenerationType.SEQUENCE, generator="member_complain_history_seq")
    @SequenceGenerator(sequenceName="ms_mc_member_complain_history_seq", name="member_complain_history_seq",allocationSize = 1)
    private Long id;

    /**
     * 创建时间
     */
    @Column(columnDefinition = "timestamp")
    private LocalDateTime createTime;

    /**
     * 上下级关联类型，定义在MemberRelationTypeEnum中，0-上级会员是平台 1-上级会员不是平台
     */
    @Column(columnDefinition = "int")
    private Integer relType;

    /**
     * 上级会员Id
     */
    @Column
    private Long memberId;

    /**
     * 上级角色Id
     */
    @Column
    private Long roleId;

    /**
     * 上级会员名称
     */
    @Column(columnDefinition = "varchar(200)")
    private String memberName;

    /**
     * 下级会员Id
     */
    @Column
    private Long subMemberId;

    /**
     * 下级角色Id
     */
    @Column
    private Long subRoleId;

    /**
     * 投诉内容(摘要)
     */
    @Column(columnDefinition = "varchar(400)")
    private String content;

    /**
     * 投诉原因
     */
    @Column(columnDefinition = "varchar(400)")
    private String reason;

    /**
     * 备注（投诉单号）
     */
    @Column(columnDefinition = "varchar(200)")
    private String remark;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public LocalDateTime getCreateTime() {
        return createTime;
    }

    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }

    public Integer getRelType() {
        return relType;
    }

    public void setRelType(Integer relType) {
        this.relType = relType;
    }

    public Long getMemberId() {
        return memberId;
    }

    public void setMemberId(Long memberId) {
        this.memberId = memberId;
    }

    public Long getRoleId() {
        return roleId;
    }

    public void setRoleId(Long roleId) {
        this.roleId = roleId;
    }

    public String getMemberName() {
        return memberName;
    }

    public void setMemberName(String memberName) {
        this.memberName = memberName;
    }

    public Long getSubMemberId() {
        return subMemberId;
    }

    public void setSubMemberId(Long subMemberId) {
        this.subMemberId = subMemberId;
    }

    public Long getSubRoleId() {
        return subRoleId;
    }

    public void setSubRoleId(Long subRoleId) {
        this.subRoleId = subRoleId;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getReason() {
        return reason;
    }

    public void setReason(String reason) {
        this.reason = reason;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }
}
